package com.itheima.mydemo.test3;

public class Test {
    public static void main(String[] args) {
        //新建狗对象猫对象
        Dog d = new Dog();
        Cat c = new Cat();
        //通过.调用方法
        d.eat();
        d.drink();
        c.eat();
        c.drink();
    }
}
